Load Management in Hybrid Electrical Systems

ABSTRACT

Various implementations described herein are directed to systems and methods for managing a plurality of loads connected to a plurality of power sources using a switching apparatus. Apparatuses described herein may include multi-throw switches designed for fast and efficient switching of loads. Methods described herein may include selecting one or more loads from a group of loads to connect to one or more alternative power sources, and selecting one or more loads to connect to a main (e.g. utility) electrical grid.

CROSS-REFERENCE TO RELATED APPLICATIONS

The present application is a continuation of U.S. application Ser. No.15/584,138, filed May 2, 2017, which claims the priority benefit of U.SProvisional Patent Application No. 62/340,688, filed May 24, 2016,entitled Load Management in Hybrid Electrical Systems. The patents andpatent applications listed in this paragraph are hereby incorporated byreference in their entireties.

BACKGROUND

Some electrical systems may feature multiple electrical power sourcesand electrical loads. For example, a home may be connected to a utilityelectrical grid as well as to an inverter converting direct current (DC)electrical power from photovoltaic generators or batteries toalternating current (AC). The inverter, in many cases, is not connectedto electrical grid. It is sometimes desirable to switch the power sourceconnected to the load. For example, it may be desirable to powerhousehold loads from the inverter during the daytime and from the gridat night. In some scenarios, a drop in electrical power output by theinverter may require moving some loads from the inverter output to thegrid. There is a need for methods and apparatuses to facilitate smoothtransitions when switching loads from one power source to another.

SUMMARY

The following summary is a short summary of some of the inventiveconcepts for illustrative purposes only, and is not intended to limit orconstrain the inventions and examples in the detailed description. Oneskilled in the art will recognize other novel combinations and featuresfrom the detailed description.

Embodiments herein may employ methods, systems, and apparatuses forswitching electrical loads between power sources.

In illustrative embodiments comprising one or more electrical systems, agroup of electrical loads may be electrically connectable to a pluralityof electrical power sources. For example, a home comprising dozens ofelectrical appliances may be connectable to an electrical grid inaddition to one or more alternative power sources (e.g. photovoltaicgenerator(s), battery(ies), windmill(s), fuel cell(s), flywheel(s),etc.). The alternative power sources may serve as backup power supplies,to ensure continuous supply of power to the load during a grid outage.In some embodiments, the alternative power sources may complement thegrid during regular grid operation. For example, alternative powersources may supply electrical power to a load, and in case ofinsufficient alternative power generation (i.e. when the load requiresmore power than that produced by the alternative power source),compensating power may be drawn from the grid.

In some embodiments, the alternative power source may be electricallyconnectable to the grid. An electrical connection between thealternative power source and the grid may enable the alternative powersource to feed the grid at times of excess alternative power generation(i.e. when the alternative power source is producing more power thanconsumed by the load). In some embodiments, the alternative power sourcemay not be electrically connectable or connected to the grid, and excessalternative power generated by the alternative power source may bestored on energy storage devices (e.g. batteries, flywheels) or utilizedto power additional loads. In some embodiments, where the alternativepower source is not connected to the grid and no energy storage deviceis available, additional loads may be connected to the alternative powersource, to increase the utilized power generated. For example, a systemmay be configured to turn on not-time-critical loads (e.g. washingmachine, dryer, air-conditioner, electric car and/or water-boiler) attimes of excess power generation by the alternative power source. Insome embodiments, if no additional loads are available, the alternativepower source may be limited to producing no more than the power consumedby the load.

Management of the loads connected to the alternative power source may bedesigned according to time-specific and location-specific policies andregulations regarding alternative power sources. For example, in somelocations, local utilities may pay a feed-in tariff to local alternativepower producers. The feed-in tariff may be higher than, lower than orequal to the rate charged by utilities for power drawn from the grid. Inthese locations, it may be profitable to connect an alternative powersource to the grid when the alternative power source is producing morepower than required by connected loads. In this manner, the grid mayfunction as a load, drawing power from the alternative power source.

In some locations, local utilities might not pay a feed-in tariff, inwhich case the alternative power generator owner is not compensated forexcess power supplied to the grid. In these locations, when analternative power source is producing more power than that required bylocal loads, it may be beneficial to store the excess power on an energystorage device (e.g. a battery or flywheel) for later consumption. Inone arrangement, the excess power stored on the energy storage devicemay later be used for self-consumption. In some cases, for example whereenergy storage devices are not available, excess generation may beutilized to reduce the power that local loads require at a later time,for example, to turn on air conditioners to cool a house, turn on awater boiler, charge an electric car, or turn on a dishwasher or washingmachine. In another arrangement, it may be desirable to decrease thepower generated by the alternative power source, to match the generationto the load requirements. For example, this may be advantageous where noadditional loads or energy storage devices are available.

In some embodiments, a load may be divided into multiple smaller loads,with each load selectively connected to either an electrical grid or analternative power source. Determining which loads to connect to anelectrical grid and which loads to connect to an alternative powersource may depend on local feed-in policies and may be carried outaccording to various methods disclosed herein. For example, in locationswhere the feed-in tariff is non-existent or lower than the cost ofconsuming power from the grid, it may be desirable to connect loads tomaximize the power drawn from the alternative power source forself-consumption or for storing for later self-consumption, while notsurpassing the power generated by the alternative power source. Inlocations where the feed-in tariff is higher than the cost of consumingpower from the grid but the allowable feed-in power is limited, it maybe desirable to connect loads to maximize the power fed to the gridwithout surpassing the allowable feed-in limit.

Various algorithmic methods may be used to connect loads to thedifferent power sources in an optimal manner. For simplicity, thedescriptions disclosed herein assume that the feed-in tariff (if oneexists) is lower than the cost of drawing power from the grid, i.e. itis beneficial to maximize the power generated by alternative powersource for self-consumption. It is understood that this is merely anillustrative scenario, and that the same methods may be modified by oneof ordinary skill in the art to reverse the optimality criterion (i.e.maximize the power fed to the grid) and are included within the scope ofthe disclosure.

In some embodiments, a “brute force search” may be carried out, with thetotal consumption of every possible combination of loads calculated, andthe group of loads corresponding to the highest total consumption whichdoes not surpass the alternative power source generation connected tothe alternative power source, and all other loads connected to the gridmay be selected. In some embodiments, a brute force search may becarried out at frequent intervals, such as once-per-second, to ensureoptimal usage of alternative power resources. In some embodiments, thenumber of loads may render a brute-force search unfeasible for frequentarrangement of load division. In these embodiments, a brute-force searchmay be carried out less frequently (e.g. once every five minutes).Additionally, or alternatively, in these embodiments, the brute forcesearch may include faster heuristic methods dividing the loads betweenthe power sources at shorter regular intervals. In some embodiments, oneor more changes in generation or load levels may trigger aredistribution of loads according to optimality criteria.

Switching circuits and control thereof may be designed for rapid andefficient switching of loads between power sources according toillustrative embodiments. Some embodiments may include switchingcircuits comprising one or more parallel-connected switching devices.For example, an illustrative single-pole-multi-throw (SPMT) switch maybe implemented using multiple parallel-connected branches. Each branchmay include a transistor (e.g. MOSFET—Metal Oxide Semiconductor FieldEffect Transistor, or IGBT—Insulated Gate Bipolar Transistor) inparallel to an electromechanical relay. The relay may provide lowsteady-state resistance and the transistor may provide a fast switchingresponse and limit the voltage drop over the relay during switching.

In some illustrative embodiments, electrical distribution boards mayinclude one or more integrated switching circuits for connecting one ormore subsidiary circuits of the distribution board to a selected powersource of one or more power sources. In some embodiments, distributionboards may be originally designed including switching circuits forconnecting subsidiary circuits to different power sources. In someembodiments, a switching circuit may be retrofit to an existingdistribution board to add load-switching functionality.

To facilitate smooth switching of a load from one power source toanother, some embodiments may include synchronizing power sourcevoltages to avoid providing a load with a supply voltage signalfeaturing discontinuities. For example, in some embodiments, a powerinverter converting direct current (DC) power from a DC power source toalternating current (AC) power may be synchronized with an electricalgrid and configured to output an AC voltage of the same magnitude,frequency and phase as the grid.

Further embodiments include user interfaces for monitoring load divisionin exemplary power systems. A system owner or operator may be able toview a list of system loads and power sources, with a mapping betweeneach load and the power source powering it. In some embodiments, thelist may be a graphical user interface (GUI) viewable on a computingdevice, such as a computer monitor, tablet, smart-television,smartphone, or the like. In some embodiments, the system operator may beable to manually switch loads from one power source to another throughthe GUI (e.g. by pressing buttons).

As noted above, this Summary is merely a summary of some of the featuresdescribed herein and is provided to introduce a selection of concepts ina simplified form that are further described below in the DetailedDescription. The Summary is not exhaustive, is not intended to identifykey features or essential features of the claimed subject matter and isnot to be a limitation on the claims.

BRIEF DESCRIPTION OF THE DRAWINGS

These and other features, aspects, and advantages of the presentdisclosure will become better understood with regard to the followingdescription, claims, and drawings. The present disclosure is illustratedby way of example, and not limited by, the accompanying figures.

FIG. 1 is part-schematic, part block diagram of an electrical systemaccording to illustrative embodiments.

FIG. 2 is a flow diagram of a method for load management in anelectrical system according to illustrative embodiments.

FIG. 3 is a part-schematic, part block diagram of an electrical systemaccording to illustrative embodiments.

FIG. 4 is a part-schematic, part block diagram of part of aload-switching circuit according to illustrative embodiments.

FIGS. 5A-5D are flow diagrams of methods for switching according toillustrative embodiments.

FIG. 6 is a part-schematic, part block diagram of an electrical systemaccording to illustrative embodiments.

FIGS. 7A-7B are illustrative mockups of a user interface for anelectrical system according to illustrative embodiments.

FIG. 8 is a flow diagram of a method for load management in anelectrical system according to illustrative embodiments.

FIGS. 9A-9E are flow diagrams of methods for load management in anelectrical system according to illustrative embodiments.

FIG. 10 is a part-schematic, part block diagram of a system for voltagesynchronization according to illustrative embodiments.

DETAILED DESCRIPTION

In the following description of various illustrative embodiments,reference is made to the accompanying drawings, which form a parthereof, and in which is shown, by way of illustration, variousembodiments in which aspects of the disclosure may be practiced. It isto be understood that other embodiments may be utilized and structuraland functional modifications may be made, without departing from thescope of the present disclosure.

For clarity and reduction of visual noise, many of the figures disclosedherein feature single-line electrical connections where multi-lineconnections would normally be used. It is to be understood that somesingle-line electrical connections would be implemented in someembodiments as two lines (e.g. a direct-current (DC) positive line and adirect-current (DC) negative/ground line) or three or more lines (e.g.some three-phase alternating-current (AC) systems feature three lines,and some include a fourth, “neutral” line).

Reference is now made to FIG. 1, which is part-schematic, part blockdiagram of an electrical system according to illustrative embodiments.Electrical system 100 may comprise power generation system 101, grid108, storage device 104, switching circuit 103 and loads 102. Powergeneration system 101 may include one or more renewable power sources,such as photovoltaic (PV) generators (e.g. PV cells, PV modules, PVshingles etc.), windmills, hydroelectric generators etc. Grid 108 may bea utility grid providing alternating-current (AC) power. In some locales(e.g. much of Europe, Asia, Africa and the Middle East) grid 108 mayprovide power at a voltage of about 220V-240V RMS at a frequency ofabout 50 Hz, and in some locales (e.g. North America) grid 108 mayprovide power at a voltage of about 120V RMS at a frequency of about 60Hz. Grid 108 may be capable of providing significantly more power thanpower generation system 101. Storage device 104 may comprise one or moreof battery(ies), flywheel(s), pumped-storage or thermal storage devices.Loads 102 may comprise large or small machines, household appliances,lighting circuits and more.

Still referring to FIG. 1, switching circuit 103 may comprise one ormore switches (e.g. transistor switches such as MOSFETs or IGBTs, and/orrelays) configured to connect and disconnect some or all of loads 102 togrid 108, power generation system 101 and/or storage device 104.Switching circuit may be a single component installed on a buildingelectrical distribution panel, or may be comprised of many smallswitching circuits distributed in different locations within thebuilding. For example, some electrical outlets may include a switch forconnecting the outlet to different power sources (e.g. power generationsystem 101, grid 108 or storage device 104).

Still referring to FIG. 1, controller 105 may control the switching ofswitching circuit 103. Controller 105 may comprise a control device suchas a microprocessor, Digital Signal Processor (DSP), Field ProgrammableGate Array (FPGA), Application Specific Integrated Circuit (ASIC), etc.In some embodiments, controller 105 may include or be coupled tosensors/sensor interfaces and/or measurement devices, such as voltage,current and/or power sensors. The measurement devices, sensors, orsensor interfaces may supply the controller 105 with informationregarding current operation of power generation system 101 or of one ormore components of power generation system 101. For example, themeasurement devices, sensors, or sensor interfaces may provideinformation to controller 105 indicative of the power generated by powergenerating system 101, the power consumed by loads 102, the ambienttemperature and/or the energy stored on storage device 104, or the like.Controller 105 may further comprise memory device 110 for storingoperational data such as load indexes, load magnitudes, code to be runby the controller 105 and more. Memory device 110 may be any kind ofmemory device that has sufficient processing capacity for real-timeapplications (e.g. flash, Electrically Erasable Programmable Read-OnlyMemory (EEPROM), Random Access Memory (RAM), Solid State Devices (SSD)or other memory devices).

In some embodiments, controller 105 may by physically located adjacentlyto switching circuit 103, and may directly supply control signals to theswitching components of switching circuit 103. For example, controller105 may directly apply a voltage signal to a terminal of a switchingelement of switching circuit 103. In some embodiments, one or morecommunication devices may communicatively interconnect one or moresystem components. For example, controller 105 may be remotely located(e.g. a remote server, or as a cloud software service), and may comprisecommunication device 107. Communication device 107 may be configured tocommunicate with communication device 118, with communication device 118including a control system or controller for controlling the switchingof switching circuit 103. Power generation system 101 may includecommunication device 106. Communication device 106 may be configured tocommunicate with communication device 107 and/or communication device118. For example, communication device 106 may report current levels ofpower production to communication device 107 and/or communication device118. In some embodiments, storage device 104 may include communicationdevice 109. Communication device 109 may include a controller forconfiguring the mode of operation of storage device 104 (e.g. charging,discharging, or neither). Communication device 109 may communicateinformation regarding the status of storage device 104 (e.g. the currentmode of operation of storage device 104 and the currently stored energylevel of storage device 104).

Still referring to FIG. 1, communication devices 106, 107, 118 and/or109 may be variously implemented. For example, communication devices106, 118 and/or 109 may communicate over power lines, using Power LineCommunication (PLC) methods and/or acoustic communication methods. Insome embodiments, communication devices 106, 107, 118 and/or 109 maycomprise wireless transceivers, and may communicate using wirelesstechnologies and protocols, such as ZigBee™, Wi-Fi, Bluetooth™, and/orcellular networks.

Reference is now made to FIG. 2, which shows a flow diagram of a methodfor load management in an electrical system according to illustrativeembodiments. Conventional load management methods consider the problemof selecting a group of loads to provide with power at times wherecurrent power resources may be insufficient to power all loads connectedto a power source. Methods disclosed herein may include but are notlimited to scenarios where a utility grid is able to supply all loadswith required power, but it may be beneficial to the system manager tominimize the power drawn from the grid by maximizing the power drawn andutilized from an alternative power source (e.g. in locales where thealternative power source may not inject power to the grid, or thefeed-in tariff is lower than the cost of drawing power from the grid).

Efficient management of loads connectable to multiple power sources mayenable decoupling of the power sources and decrease the costs associatedwith system implementation. For example, a grid-tied photovoltaic (PV)inverter must comply with various safety standards and regulations.Furthermore, installing a grid-tied PV inverter may require approval bylocal utilities, a process which may delay system installation bymonths. By providing effective management of loads connectable to a PVinverter and the grid, implementation of method 200 may increase thefinancial feasibility of installing of a PV inverter which is notnecessarily tied to the grid, thereby possibly allowing a cheaper PVinverter to be used (e.g. an inverter which might not be designed tocomply with all grid-tied inverter requirements), and reduce the timerequired to obtain utility permits for installation of a PV system.

Method 200 may be carried out by a device or a controller, such ascontroller 105 of FIG. 1. At step 201, the controller or device mayreceive one or more measurements of power generation and current loadlevels. For example, the controller or device may receive power producedby a generator (such as power generation system 101 of FIG. 1) and anamount of power consumed by a group of one or more loads (such as loads102 of FIG. 1). The measurements may be directly measured bysensors/sensor interfaces or devices included in the controller (e.g.controller 105 of FIG. 1), or may be provided to the controller ordevice via one or more communication device (e.g. communication devices106, 107, 118 and 109 of FIG. 1). At step 202, the controller or devicemay compare the power generation measurements to the current load levelmeasurements.

As a result of comparing the power generation measurements to thecurrent load level measurements, the controller or device may determinethat the amount of generated power is greater than the current loadlevel (shown as generation>load), that the amount of generated power isequal to the current load level (shown as generation=load), or that theamount of generated power is less than the current load level (shown asgeneration<load). In theory, a power system can operate under thecondition load=generation indefinitely. In practical electrical supplysystems, it is generally desirable to maintain the operationalload<generation condition, with a system-defined excess generationmargin (e.g. load≤generation+ϵ, where ϵ is the required excessgeneration margin). Such a mode of operation may allow continuous supplyto the load even in case of a sudden reduction in generation or a suddenincrease in load.

For simplicity's sake, it will be assumed when describing illustrativemethods disclosed herein that the load=generation condition is anacceptable condition for continuous system operation, with no excessgeneration margin required. It is understood that one of ordinary skillin the art can slightly modify methods disclosed herein to incorporaterequirements for excess generation margins. For example, instead ofaccepting the condition load=generation for sustainable systemoperation, the system may require the condition load≤generation−ϵ forsome system-defined ϵ). Such modified methods are within the scope ofthe embodiments disclosed herein.

Returning to FIG. 2, processing may proceed to one of several differentsteps depending on the result of the comparison of step 202. If theresult load=generation is obtained at step 202 (that is, if the amountof generated power is equal to the current load level), the system maybe operating at a point which does not require corrective action, andthe controller or device may proceed to step 203. At step 203, thecontroller or device may wait a period of time before looping back tostep 201. In some embodiments, the controller may remain at step 203until an interrupt is received. In one example, a received interrupt maycomprise a change in load and/or generation measurements. If aninterrupt is received at step 203, processing may loop back to step 201.In some embodiments, the controller or device carrying out method 200may engage in other tasks or computations while waiting in step 203. Forexample, the controller or device may execute the method of FIG. 9A(discussed in detail below) for several generation and/or load levelswhich may be indicative or predictive of future generation and/or loadlevels.

If the result load>generation is obtained at step 202 (that is, if thecurrent load level is greater than the amount of generated power), itmay indicate a condition in which a generator (e.g. power generationsystem 101 of FIG. 1) is unable to power all the loads currentlyconnected to it. It may be desirable to switch one or more loads fromthe generator to a different power source, such as a backup storagedevice (e.g. storage device 104 of FIG. 1) or the grid (e.g. grid 108 ofFIG. 1). Accordingly, if the current load level is greater than theamount of generated power), processing may proceed to step 204. At step204, the connections between the various loads, the generator, and thegrid may be reconfigured. Reconfiguration of the connections maycomprise determining which loads should be disconnected from thegenerator. Reconfiguration of the connections may further comprisedetermining which of the disconnected loads should be connected to thegrid and which of the disconnected loads should be connected to a backupdevice. In some embodiments, step 204 may include switching one or moreloads from the generator to the grid, and then switching one or moredifferent loads from the grid to the generator, to reach a preferredoperating condition. In one arrangement, a preferred operating conditionmay be maximization of the utilization of the generator output withoutsurpassing the power producing capacity of the generator).

In one scenario, a first load and a second load may currently beconnected to a generator, and a third load and a fourth load maycurrently be connected to a grid. At step 202, the controller or devicemay have determined that the current load level is greater than theamount of generated power. Processing may have proceeded to step 204,where the controller or device may analyze the connections between theloads and the generator and/or grid. In a first example, the controlleror device may determine that maximal utilization of the generator outputmay be achieved if the third and fourth loads are connected to thegenerator and the first and second loads are connected to the grid.Accordingly, reconfiguration of the connections at step 204 in the firstexample may include switching the connections of the first and secondloads from the generator to the grid, and switching the connections ofthe third and fourth loads from the grid to the generator, to reach apreferred operating condition. In a second example, the controller ordevice may determine that maximal utilization of the generator outputmay be achieved if the third load is reconfigured to connect to thegenerator and the first and second loads are reconfigured to beconnected to the grid (while the fourth load retains its connection tothe generator). Accordingly, reconfiguration of the connections at step204 in the second example may include switching the connection of thethird load from the generator to the grid and switching the connectionof the first and second loads from the grid to the generator, to reach apreferred operating condition The selection of which load(s) to switchfrom the generator to the grid/backup device, and vice versa, may becarried out using a myriad of methods, some of which are disclosedherein (e.g. the method of FIG. 9A and method 980 of FIG. 9B).

In some embodiments, the controller or device executing method 200 mayhave access to a list detailing system loads. Each load entry mayindicate the power source powering that load and the current powerconsumed by that load. A graphical example of such a list is illustratedin FIGS. 7A and 7B (discussed in detail below). The list may be storedin a memory device similar to or the same as memory device 110 of FIG. 1(e.g. flash, Electrically Erasable Programmable Read-Only Memory(EEPROM), Random Access Memory (RAM), Solid State Devices (SSD) or othermemory devices), and may be read and edited by the controller. Forexample, after the controller switches the connections of one or moreloads in step 204, the controller may update the list to reflect theupdated connections.

After step 204, processing may return to step 202, where powergeneration measurements are again compared to the current load levelmeasurements. In some embodiments, step 204 may be reached several timesin succession following step 202 (i.e. the method jumps between steps202 and 204 in succession), each time one or more loads being switchedto the grid or a backup device. In some embodiments, implementation ofstep 204 may ensure that at the end of step 204 the currentgenerator-connected load is smaller than or equal to the amount ofgenerated power, and processing may continue at step 203 or step 205(these variations not explicitly depicted in the flow chart).

If the result load<generation is obtained at step 202 (that is, if thecurrent load level is less than the amount of generated power), it mayindicate a condition in which a generator (e.g. power generation system101 of FIG. 1) is generating more power than is required by the loadsconnected to it. In this condition, it may be desirable for the systemto reach a new operating condition which makes better use of thepower-generating capacity of the generator. Accordingly, processing mayproceed to step 205, where the controller or device may determine if anyloads (e.g. one or more loads of loads 102 of FIG. 1) are connected tothe grid (e.g. grid 108) and/or a backup device (e.g. storage device104). The controller or device may determine whether any loads areconnected to a grid and/or a backup device based on the detailed list ofloads (described above with reference to step 201). If it is determined,at step 205, that one or more loads are connected to the grid or abackup device, processing may proceed to step 209. At step 209, thedevice or controller may switch one or more selected loads from the gridand/or backup device to the generator. The selection of the one or moreloads to switch to the generator may be carried out using a myriad ofmethods, some of which are disclosed herein (e.g. the method of FIG. 9Aand method 940 of FIG. 9C).

If the device or controller successfully selects one or more loads toswitch to the generator at step 209, processing may proceed to step 203.If the device or controller is unable to select one or more loads forswitching to the generator at step 209 the method may proceed to step206. For example, the device or controller may be unable to select oneor more loads for switching to the generator if switching any singleload from the grid/backup device to the generator would result in anunacceptable load>generation condition (i.e. if switching the singleload would result in the current load level being greater than thegenerated power). At step 206, the device or controller may determine ifa storage device is available. If a storage device is available (e.g. astorage device similar to or the same as storage device 104 of FIG. 1),the method may proceed to step 208. At step 208, the device orcontroller may connect the storage device to the generator. For example,controller 105 of FIG. 1 may configure switching circuit 103 to connectstorage device 104 to power generation system 101. Subsequent to thisconfiguration, power generation system 101 may store excess power instorage device 104. Processing may then return to step 203, discussedabove.

If no storage device is available at step 206, the method may proceed tostep 207, where the device or controller may either add a load to bepowered by the generator or reduce the power generated by the generator.A storage device may not be available if the system does not include astorage device, or if all storage devices are already maximallyutilized. The controller or device may be configured to connect certainloads to the generator in case of excess generation with no availablestorage. For example, the device or controller may connect an airconditioning system to the generator to reduce the temperature of a homeduring summer, heat water in a water boiler or turn on a washing machineor dishwasher, which may reduce power consumption later on (since inmany cases these devices would otherwise be turned on later, when theremight not be available excess power generated by the generator). If noloads are configured to be turned on in case of excess power generation,at step 207, the device or controller may reduce the power generated bythe generator. For example, if method 200 is applied to a system wherethe generator includes a photovoltaic (PV) generator coupled to activepower electronics (e.g. one or more DC-DC converters and/or one or moreDC-AC inverters) configured to control the power output by the PVgenerator, the device or controller may configure the active powerelectronics to reduce the power drawn from the PV generator, such thatit matches the current load level. From step 207, the method may proceedto step 203.

Reference is now made to FIG. 3, which is a part-schematic, part blockdiagram of an electrical system according to illustrative embodiments.Electrical system 300 may comprise power generation system 301, grid308, switching circuit 303, controller 305 and loads 302 a, 302 b . . .302 n. Grid 108 may be similar to or the same as grid 108 of FIG. 1.Loads 302 a, 302 b . . . 302 n may be collectively referred to as “loads302” and may be similar to or the same as load 102 of FIG. 1.

Still referring to FIG. 3, power generation system 301 may be similar toor the same as power generation system 101 of FIG. 1. In theillustrative example of FIG. 3, power generation system 301 comprisesphotovoltaic (PV) source 311, power manager 312, storage device 304 andinverter 313. PV source 311 may comprise a PV generator (e.g. PV panels,cells or shingles) one or more strings of series-connected PVgenerators. In some embodiments, PV source 311 may comprise one or morePV generators, which may be divided into groups of one or more PVgenerators, with a direct-current to direct-current (DC/DC) converter(e.g. a Buck, Boost, Buck-Boost, Buck+Boost, Flyback, Cuk or Forwardconverter, or a charge pump) coupled to each group. The DC/DC convertercoupled to each group may be configured to control the power drawn fromeach group. For example, the DC/DC converters may increase or decreasethe power drawn from each group of PV generators. Power manager 312 maycomprise one or more switches, and may be configured to direct the powerfrom PV source 311 to inverter 313 (which may be a direct-current toalternating-current (DC/AC)) and/or to storage device 304. Storagedevice 304 may be similar to or the same as storage device 104 ofFIG. 1. In the illustrative embodiment of FIG. 3, the storage device 304is connectable (via power manager 312) to inverter 313 via power manager312. In some embodiments, storage device 304 may be directly connectableto loads 302, similar to the illustrative embodiment of FIG. 1. Inverter313 may be configured to convert direct-current (DC) power received fromPV source 311 and/or storage device 304 to alternating-current (AC)power suitable for powering loads 302. In some embodiments, multiplestorage devices may be used, with one or more storage devices directlyconnectable to loads (e.g. the arrangement illustrated in FIG. 1) andone or more storage device not directly connected to loads (e.g. thearrangement of FIG. 3).

Still referring to FIG. 3, circuit breaker 307 may couple (e.g. connect)power generation system 301 to switching circuit 303. Circuit breaker307 may be configured to disconnect power generation system 301 fromswitching circuit 303 in the event of a potential safety hazard, such asdetection of a leakage current. For example, a leakage current may bedetected if the current leaving power generation system 301 in thedirection of switching circuit 303 is not equal to the current returningin the direction of power generation system 301. In some embodiments,circuit breaker 307 may be replaced by a plurality of circuit breakersdeployed similarly to circuit breakers 306 a, 306 b . . . 306 n(discussed below). Each circuit breaker of the plurality of circuitbreakers may be configured to disconnect a single load of loads 302 fromswitching circuit 303.

Still referring to FIG. 3, power generation system 301, controller 305and switching circuit 303 may include communication devices similar toor the same as communication devices 106, 107 and 118 of FIG. 1. Thecommunication devices may be configured to communicate with one anothersimilarly to the manner described with regard to FIG. 1. For brevity,the communication devices have not been explicitly depicted anddescribed with regard to FIG. 3.

Circuit breakers 306 a, 306 b . . . 306 n may be collectively referredto as “circuit breakers 306.” Circuit breakers 306 may couple (e.g.connect) grid 308 to switching circuit 303. The circuit breakers mayautomatically disconnect one or more loads of loads 302 from grid 308 inthe event of a potentially unsafe condition, for example detection ofleakage current. Leakage current may be detected if the current fromgrid 308 in the direction of a load of loads 302 is not equal to thecurrent returning in the direction of grid 308.

Still referring to FIG. 3, circuit breakers 306, switching circuit 303and circuit breaker 307 may be deployed on an electrical distributionboard located on a premises housing loads 302. One of the potentialadvantages of integrating alternative power sources (such as powergeneration system 301) according to the illustrative embodiment of FIG.3 is the seamless integration of a switching device such as switchingcircuit 303. By installing switching circuit 303 serially in-betweencircuit breakers 306 and loads 302, from the “grid perspective” (i.e.the perspective of the utility operating grid 308) the electricalconnection to the premises distribution board and the electricalinterface between the premises distribution board and the grid may nothave changed at all. By installing generation system 301 in a mannerwhich does not significantly change the “grid perspective,” the processof applying for and receiving safety clearance from utilities andregulatory bodies may be faster and simpler than in case of aninstallation which might change the interface between the grid and apremises distribution board.

Switching circuit 303 may comprise switches 309 a, 309 b . . . 309 n,which may be collectively referred to as “switches 309”. Each switch ofswitches 309 may enable a load of loads 302 to be connected to one ormore power sources. For example, in the illustrative embodiment of FIG.3 (featuring single-line electrical connections), switch 309 a may be asingle-pole triple-throw switch connected to load 302 a on one end(single pole), and connectable on the other end to grid 308 (via circuitbreaker 306 a) or power generation system 301 (via circuit breaker 307),or no power source at all. In embodiments including a storage devicedirectly connectable to loads (e.g. storage device 104 connectable toloads 102 via switching circuit 103) of FIG. 1, an additional throw maybe added to each switch of switches 309, enabling each switch to alsoconnect its corresponding load to the storage device. Switches 309 areillustrated in FIG. 3 as having a single pole, since the electricalconnections of FIG. 3 are indicated by single lines. In systemsrequiring connecting and disconnecting two or more lines (e.g. positiveand negative DC lines), double-pole, triple-pole or multi-pole switchesmay be used instead.

In some embodiments, switches 309 may be packaged and deployed asdiscrete components. For example, each switch of switches 309 may beenclosed in its own enclosure and be individually connected between aload of loads 302 and a circuit breaker of breakers 306. In someembodiments, a plurality of switches 309 may be packaged togetherforming switching circuit 303, with switching circuit 303 packaged as asingle component and featuring one enclosure. In some embodiments,switching circuit 303 may designed to enable retrofitting to an existingdistribution board (e.g. by connecting switching circuit 303 betweencircuit breakers 306 and loads 302).

Switching circuit 303 may further comprise measuring devices (notdepicted explicitly for reduction of visual noise) for measuring thevoltage, current and/or power supplied to each load of loads 302. Insome embodiments, the voltage supplied to each load of loads 302 may beabout the same (e.g. grid voltage, or the voltage supplied by powergeneration system 301), requiring only current measurements to enablecalculation of the power drawn by each load. In some embodiments, asingle measuring device may measure the total voltage, current and/orpower supplied to loads 302 connected to power generation system 301,with calculation of the power drawn by each load of loads 302 enabled bytemporarily disconnecting each load and subtracting the new powermeasurement from the total power measurement. As a numeric example, ifthe total power consumed by loads connected to power generation system301 is 1000[W], and the power consumed by load 302 a (which is connectedto power generation system 301) is 100[W], switching circuit 303 maymeasure a total of 1000[W] when all loads are connected, temporalitydisconnect load 302 a, measure 900[W] and calculate that the powerconsumed by load 302 a is 1000[W]−900[W]=100[W]. Switching circuit 303may further comprise a communication device (not explicitly depicted)for sending measurements to controller 305 and/or receiving switchingcommands from controller 305.

Controller 305 may be similar to or the same as controller 105 of FIG.1, and may be configured to control the switching of switching circuit303 according to method described herein (e.g. method 200 of FIG. 2).Controller 305 may further comprise a communication device (notexplicitly depicted) for receiving measurements from and sendingcommands to switching circuit 303 and/or power generation system 301.

Reference is now made to FIG. 4, which illustrates part of aload-switching circuit according to illustrative embodiments. Theload-switching circuit may comprise switch 409. Switch 409 may comprisepole 410 connected to load 402. Load 402 may be similar to or the sameas any of loads 302 of FIG. 3. Switch 409 may further comprise aplurality of throws 406 a, 406 b . . . 406 n, referred to collectivelyas “throws 406”, with each individual, non-specific throw of throws 406a, 406 b . . . 406 n referred to as “throw 406”. Each throw of throws406 may be coupled (e.g. connected) to load 402 on one end via pole 410,and may be coupled to a power source on the other end. In someembodiments, one or more of throws 406 might not be coupled to a powersource (e.g. a generic n-throw switch may be deployed in a system wherethe number of connectable power sources is less than the number ofthrows comprising the switch). Each throw of throws 406 may be switchedto the ON position to connect load 402 to the power source coupled tothe throw. For example, when throw 406 a is in the ON position, load 402may be connected to grid 408. When throw 406 b is in the ON position,load 402 may be connected to inverter 413, which may be part of a powergeneration system similar to or the same as power generation system 301of FIG. 3. When throw 406 c is in the ON position, load 402 may beconnected to storage device 404, which may be similar to or the same asstorage devices described with regard to storage device 104 of FIG. 1.When throw 406 n is in the ON position, load 402 might not be connectedto any power source.

Each throw 406 may comprise one or more switching elements. For example,each throw 406 may comprise transistor coupled in parallel to anelectromechanical relay. Referring to throw 406 a, throw 406 a maycomprise electromechanical relay R1 coupled in parallel with transistorQ1. In general, electromechanical relays may have lower conductingresistance and lower losses than transistors, but electromechanicalrelays may be sensitive to high-voltage switching (e.g. constantswitching with a significant voltage drop between the relay terminalsmay stress the relay and shorten the lifetime of the relay). In someembodiments, connecting an electromechanical relay and a transistor inparallel and switching them in an efficient manner (e.g. according tothe methods of FIGS. 5A and 5B, discussed below) may reduce switchinglosses and prolong the life of the switching elements.

As an example, in electrical distribution boards that may feature aswitch similar to 409, it may be desirable to use MOSFETselectromechanical relays rated to withstand an open-circuit voltage ofabout 600V. MOSFETs with a 600V-rating may have an “ON-state resistance”(R_(ON)) of about 15 mΩ−100 mΩ, with a 15 mΩ MOSFET costing about $5,and a 100 mΩ MOSFET costing $1. In contrast, a 600V-ratedelectromechanical relay may have an R_(ON) of about 1 mΩ−2 mΩ, and maycost about $0.5. A large load (e.g. load 402) connected to switch 409may draw a current of at least 15 A, leading to losses which are atleast P_(loss)=I_(RMS) ²·R_(ON)=15²·15e−3=3.375 W. To obtain R_(ON)=1.5mΩ, ten 15 mΩ MOSFETs may be coupled in parallel, at a total cost ofabout $50 per throw. In contrast, a single relay of resistance 1.5 mΩmay be obtained for about $0.5, and in parallel with a cheap MOSFET(e.g. a MOSFET with R_(ON)=100 mΩ, costing about $1) an equivalentresistance of 1.5 mΩ may be obtained for a total price of $1.5 perthrow, or less than 1/30-th of the price of the MOSFET-only solution. Itis to be understood that the prices and standard component propertiesdiscussed above merely reflect a potentially reasonable scenario at thetime of writing. Developments in component technology and/or changes inprice may change some or all of the example numbers cited above. Thenumerical example is used to merely illustrate one possible scenariowhere the benefits of embodiments disclosed herein may be realized, andis not to be limiting of any part of the disclosure. In someembodiments, a single switching element (e.g. transistor or relay) maybe used for each throw 406, without obtaining all of the potentialbenefits of combining switching elements.

In some embodiments, transistor Q1 may be replaced by a plurality oftransistors. For example, many MOSFETs and IGBTs feature bypass diodesallowing current to flow in one direction even when the transistor isOFF. When using these transistor, transistor Q1 may be replaced by apair of back-to-back transistors (herein referred to as “transistorsQ2”), with a common signal applied to both transistors' gates forturning the transistors ON and OFF. In the arrangement using transistorsQ2, current might not be able to flow from one side to the other withoutboth transistors being in the ON state.

The switching elements of each throw 406 may be switched by controldevice 405, which may be similar to or the same as controller 305 ofFIG. 3 and/or controller 105 of FIG. 1. Control device 405 may beconfigured to apply control signals to transistor gate terminals (e.g.terminal G1 of throw 406 a) and relay trigger terminals (e.g. terminalT1 of throw 406 a).

Reference is once again made to the single-line nature of the figuresused to describe illustrative embodiments. In a multi-line electricalsystem, each throw 406 connecting two single-terminal elements may bereplaced by multiple throws connecting multiple terminals of the twoelements. For example, grid 408 and load 402 may comprise threeterminals (“line”, “return” and “neutral”) and throw 406 a may bereplaced by three synchronized throws (i.e. the three throws receive thesame signal and switch together), each connecting a grid terminal to acorresponding terminal of load 402. Similarly, storage device 404 maycomprise two terminals (“DC positive” and “DC negative”), with throw 406c replaced by two synchronized throws connecting storage device 404 toload 402.

Reference is now made to FIGS. 5A and 5B, which illustrate methods forswitching according to illustrative embodiments. Methods 500 and 510 asillustrated in FIGS. 5A and 5B, respectively, may be applied toswitching devices comprising one or more electromechanical relays andone or more transistors (e.g. MOSFET), such as throw 406 a of FIG. 4.For simplicity, the methods will be described with regard to a switchingdevice comprising one MOSFET and one electromechanical relay, coupled inparallel. It is understood that it is similarly applicable to switchingdevices comprising multiple transistors of various types and/or multipleparallel-connected relays.

Method 500 may be utilized to switch a switching device from the OFFposition to the ON position. In the OFF position, at step 501, both theMOSFET and electromechanical relay may be in the OFF state. At step 502,the MOSFET is set to the ON state. The MOSFET may be set to the ON stateby receiving a control signal from a control device such as controldevice 405 of FIG. 4. After step 502, the switching device is in the ONposition, with about zero voltage between the switching deviceterminals, but it may not be desirable to leave the device in thisstate, due to the potentially high losses incurred by the MOSFET. Atstep 503, the electromechanical relay is set to the ON position. Theelectromechanical relay may be set to the ON position by receiving acontrol signal from a control device such as control device 405 of FIG.4. The voltage stress on the electromechanical relay during step 503 maybe about 0[V], preventing significant erosion to the relay. At step 504,the MOSFET is returned to the OFF state, leaving the electromechanicalrelay in the ON state. At the end of method 500, the switching device isin the ON position. The only losses incurred in the ON position may bethe relay losses, which may be significantly lower than the MOSFETlosses.

Method 510 may be utilized to switch a switching device from the ONposition to the OFF position. In the ON position, at step 511, theMOSFET may be in the OFF state and electromechanical relay may be in theON state. At step 512, the MOSFET may set to the ON state. The MOSFETmay be set to the ON state by receiving a control signal from a controldevice such as control device 405 of FIG. 4. At step 513, theelectromechanical relay is set to the OFF position. The voltage stresson the relay during step 513 may be about 0[V], preventing significanterosion to the relay. At step 514, the MOSFET is returned to the OFFstate, leaving the relay in the OFF state. At the end of method 510, theswitching device may be in the OFF position.

In some embodiments, switching at specific times along the AC-powersignal may offer certain benefits. For example, switching losses acrossa switch may be reduced by switching the switch from ON to OFF when nocurrent is flowing through the switch (i.e. at a “zero crossing” of theAC current signal). Similarly, switching the switch from OFF to ON maybe done when the voltage drop between the switch terminals is zero (i.e.at a “zero crossing” of the AC voltage signal between the switchterminals). Zero-voltage switching and zero-current switching may alsoreduce thermal losses and electromagnetic interference (EMI). In somescenarios, zero-voltage switching may prevent a switch operating closeto its rated voltage level from overshooting its voltage rating during aswitching transient. In a system providing AC power at 50 Hz, there willbe about 50 zero-crossings per second. The controller carrying outmethods 500 and 510 (e.g. control device 405) may receive voltage and/orcurrent measurements from sensors/sensor interfaces coupled to loads,and may use the measurements to provide an output switching signal toensure that the voltage and/or current flowing through a switch is zerobefore connecting or disconnecting the switch.

Reference is now made to FIGS. 5C and 5D, which illustrate methods forswitching according to illustrative embodiments. Methods 520 and 530 maybe applied to a switch such as switch 409 of FIG. 4. In someembodiments, a power generation system (PGS) similar to or same as powergeneration system 101 of FIG. 1 might not be connectable to a utilitygrid (e.g. grid 108). For example, a PGS might include a photovoltaicinverter which has not been certified for grid-tied applications, orlocal utilities might may not have been approved connecting the PGS to autility grid. In these and similar scenarios, loads may be switched fromthe PGS to the grid and vice-versa without connecting the PGS to thegrid. According to an illustrative embodiment, individual loads areswitched from one power source to another using a “break before make”method.

Referring to FIG. 5C, method 520 is a method for switching a load from aPGS to a grid according to an illustrative “break before make”embodiment. The initial conditions 521 of the load (e.g. load 402 ofFIG. 4) are that the load is connected to a PGS and disconnected fromthe grid. At step 522, the load is disconnected from the PGS, e.g. byusing method 510 to switch a throw similar to or the same as throw 406 bto the OFF position. At step 523, the load is connected to the grid,e.g. by using method 500 to switch a throw similar to or the same asthrow 406 a to the ON position. The final conditions 524 of the load arethat the load is connected to the grid and disconnected from the PGS.

Referring to FIG. 5D, method 530 is a method for switching a load from agrid to a PGS according to an illustrative “break before make”embodiment. The initial conditions 531 of the load (e.g. load 402 ofFIG. 4) are that the load is connected to a grid and disconnected fromthe PGS. At step 532, the load is disconnected from the grid, e.g. byusing method 510 to switch a throw similar to or the same as throw 406 ato the OFF position. At step 533, the load is connected to the PGS, e.g.by using method 500 to switch a throw similar to or the same as throw406 b to the ON position. The final conditions 534 of the load are thatthe load is connected to the PGS and disconnected from the grid.

When applying method 520 and method 530, switching is preferably fastenough to provide a near-continuous power supply to the load beingswitched. Switch drivers may be designed to switch MOSFETs (oralternative transistors) at high speeds, with switching times of severalnanoseconds, dozens of nanoseconds or hundreds of nanoseconds.Implementing fast-switching when applying method 520 and method 530 mayensure that the load is disconnected for only a very short period oftime, having negligible effect.

Reference is now made to FIG. 6, which is a part-schematic, part blockdiagram of an electrical system according to illustrative embodiments.Electrical system 600 may be similar to electrical system 300 of FIG. 3,with differences in the arrangement of electrical connectivity betweenpower sources and loads. Electrical system 600 may comprise grid 608(similar to or the same as grid 108 of FIG. 1), power generation system601 (similar to or the same as power generation system 101 of FIG. 1and/or power generation system 301 of FIG. 3) and loads 602 a, 602 b . .. 602 n (collectively referred to as “loads 602”) coupled to grid 608and power generation system 601 via switching circuit 603. Switchingcircuit 603 may comprise switches 609 a, 609 b . . . 609 n (collectivelyreferred to as “switches 609”). Each switch of switches 609 may besimilar to or the same as a switch of switches 309 of FIG. 3, or switch409 of FIG. 4. Circuit breakers 606 a, 606 b . . . 606 n (collectivelyreferred to as “circuit breakers 606”) may be coupled to or integratedwith switches 609 a, 609 b . . . 609 n, respectively. In someembodiments, each circuit breaker 606 may be integrated with a switch609 and packaged and deployed as a single device. Circuit breakers 606may be similar to or the same as circuit breaker 306 of FIG. 3. In theillustrative embodiment of FIG. 6, grid 608 and power generation system601 may “share” circuit breakers 606, i.e. each circuit breaker ofcircuit breakers 606 may disconnect a load of loads 602 (e.g. in case ofdetection of an unsafe condition) regardless of the power source theload is connected to, which may, in some embodiments, simplify thedesign and reduce the costs of an distribution board electricalcomprising switching circuit 603.

In some embodiments, electrical system 600 may further include a storagedevice (not explicitly depicted) similar to or the same as storagedevice 104 of FIG. 1, connectable to power generation system 601 and/orloads 602. Similarly, electrical system 600 may further include acontroller (not explicitly depicted) similar to or the same ascontroller 105 of FIG. 1 and/or controller 305 of FIG. 3 configured tocommunicate with (e.g. via communication devices similar to or the sameas communication devices 106 and 107 of FIG. 1) and control switchingcircuit 603 and/or power generation system 601.

Referring to FIG. 7A, an illustrative application running on a smartphone, tablet, computer, workstation server, mobile device (such as acellular device) and/or a similar computing device is shown. Theapplication may provide a list of loads of an electrical power system(e.g. electrical systems 100, 300 or 600). The application may provide adescriptive name of each load (e.g. “dining room outlet #1”, “Masterbedroom lights”). In some embodiments, where individual load values areavailable, the application may provide the current load value for eachload. In some embodiments, the application may indicate the power sourcecurrently providing each load on the list with power. The applicationmay provide an option for manually changing the power source providing aspecific load with power. For example, a user may activate (e.g. using atouchscreen on a mobile phone, or a mouse on a computer) “Switch source”button 701 located by load #4 (“Dining room lighting”), and be presentedwith the option of switching load #2 from a PV inverter to the grid or abattery. Such an action may be desirable when a system maintainer (e.g.installer or electrical worker) would like to shut down a part of theelectrical system (e.g. routine maintenance of the PV inverter) andneeds to first transfer loads connected to that part to a differentpower source. In some embodiments, automatic division of loads amongstdifferent power sources may result in suboptimal division, and manualcorrections may be beneficial.

Still referring to FIG. 7A, the application may further includeinformation regarding the current state of a storage device similar toor the same as storage device 104 of FIG. 1. For example, the systemdescribed by the application of FIG. 7A may include a battery, with theapplication displaying the current state of the battery (e.g. charging,discharging or neither charging nor discharging), the current rate ofcharging/discharging and the current energy level stored by the battery.The application may further enable a user to change the state of thestorage device, for example, by providing button 702 for switching thestorage device mode from “charge” mode to “discharge” mode.

Still referring to FIG. 7A, the application may be connected to wiredcommunication networks, wireless communication networks, and/or datanetwork(s), including an Intranet or the Internet. The application mayreceive data from and send commands to system devices (e.g. powergeneration system 101, loads 102, storage device 104 and/or switchingcircuit 103) via the computing device on which the application isexecuting. In addition to providing information and control-relatedservices to the end user, the application may receive notification of apotentially unsafe condition from one or more system-connected controland/or communication devices, and warn the user (e.g. a systemmaintenance worker). These warnings can be audio and/or visual. Theymay, for example, be a beep, tone, siren, LED, and/or high lumen LED.For example, if a circuit breaker 606 of FIG. 6a detects a leakagecurrent, it may, in addition to disconnecting load 602 a, trigger awarning to be sent (by a control and/or communication device included inelectrical system 600) to the application of FIG. 7A. The notificationmay be received by the application and the application may subsequentlytrigger one or more of the aforementioned warnings.

Reference is now made to FIG. 7B, which shows the application of FIG. 7Aproviding updated information regarding the state of an electricalsystem. The production of a system-connected PV inverter (e.g. inverter313 of FIG. 3) may decrease from the 3 kW depicted in FIG. 7A to the 1kW depicted by FIG. 7B. In response to the reduction in the PV-inverterproduction, the system may switch several loads from the PV inverter tothe grid. For example, load #1 (“Kitchen lighting”) may be switched fromthe PV inverter to the grid. Furthermore, the battery may be switchedfrom the “charge” to “discharge” mode. Additional loads may be connectedin the interim period of time as well, resulting in an increase in powerdrawn from the grid from 1910 W to 4.5 kW. The selection of the loads tobe switched from the PV inverter to the grid may be performed using thesteps discussed in reference to FIG. 2 above and those discussed belowin reference to the method of FIG. 9A and method 980 of FIG. 9B.

It is to be understood that the applications as illustrated in FIGS. 7Aand 7B are merely illustrative embodiments. User-interface applicationsmay offer many additional features such as time and date indications,graphical system illustrations, communication services, weatherforecasts, generation and load forecasts, service call capabilities andmore. Furthermore, some applications may serve several electrical powersystems, with a user able to scroll between screens indicating differentelectrical systems, and view and control each system individually.

Reference is now made to FIG. 8, which shows a flow diagram of a methodfor load management in an electrical system according to illustrativeembodiments. Method 800 may be carried out by a controller (e.g.controller 105 of FIG. 1) configured to control a switching circuit(e.g. switching circuit 103 of FIG. 1) for division of a group of loads(e.g. the loads 102 of FIG. 1) amongst a plurality of power sources(e.g. grid 108 and power generation system 101 of FIG. 1). At step 801,the controller may receive one or more current measurements of loadvalues and one or more power generation values from a generator. Forexample, the controller may receive one or more load measurementsindicating. the power consumed by loads 102 of FIG. 1. The controllermay further receive one or more power generation values indicating thepower produced by power generation system 101 and/or the powerdischarged by storage device 104. The controller may receive the one ormore load and generation measurements via a wired or wirelesscommunication device, e.g. via communication devices 106, 107, 118and/or 109.

At step 802, the controller may select a subset of loads to connect tothe generator and/or a connected storage device, with the remainder ofthe loads to be connected to the grid or to remain connected to thegrid. As discussed above, it may be desirable (e.g. in locations where afeed-in tariff is low on nonexistent) to maximize the power delivered bythe generator to loads, without surpassing the generator's capacity.This problem shall be referred to in this disclosure as the “Load SubsetProblem” (LSP). The LSP can be formulated as a variant of the “0-1Knapsack problem” (KP) The KP may be described by the followingdescription: “Given a set of items, each item having a weight and avalue, determine a subset of items to include in a collection such thatthe total weight is less than or equal to a given limit and the totalvalue is maximal”. The LSP may be formulated as a private or variantcase of the KP, where each item is a represented load, with the valueand weight each item equaling the power consumed by the correspondingload. The given limit is the generating capacity of the generator. Whenapplied to systems including a storage device which can function eitheras a generator (i.e. when discharging) or as a load (when charging), theproblem may be adapted to dynamically increase the given limit (when thestorage device is discharging) or add an item to the set, the itemhaving a value and weight of the power consumed by the storage devicewhen charging.

The KP is solvable in pseudo-polynomial time by dynamic-programming (DP)techniques. Alternatively, the problem may be solved using a “bruteforce” (BF) algorithm, i.e. calculating the total consumption of eachpossible subset of loads, and selecting the subset of maximumconsumption which still does not exceed the generator capacity. Ingeneral, BF methods run in exponential time, i.e. time proportional to2^(n), with n representing the number of loads. In systems where n isnot great (e.g. a system comprising only 10 or 20 loads), a BF algorithmmay still provide acceptable timing performance. In contrast, a DPmethod may run in time proportional to n·G, where G is the generatorcapacity. In some embodiments, the DP may provide better timeperformance, but at the cost of requiring significantly greater memoryresources. An example of a BF solution for step 802 is provided in FIG.9A. If a DP solution is preferred, a person of skill in the art will beable to implement one by via originally-written code, or obtaining codefrom other sources.

Still referring to step 802 of FIG. 8, both BF and DP solutions maydetermine that switching a significant number of loads is desirable. Inextreme cases, DF and DP solutions may determine that each load shouldbe switched from the current power source powering it to a differentpower source. Frequent switching of loads may be undesirable, as it may,in some embodiments, wear out switches and/or cause cumulative erosionof the loads. For example, in the case of some electrical appliances,constantly changing the power source may cause damage. Furthermore, inlarge systems (e.g. systems comprising tens or hundreds of loads), thetime consumed by both DP and BF methods may be too long for real-timeapplications (e.g. in case of sudden generation reduction). In someembodiments, it may be desirable to implement one or more alternativemethods which might be suboptimal with regard to the LSP, but may offerincremental improvement over current operating conditions and/or preventa situation where certain loads are not receiving enough power. Forexample, a system controller may be configured to respond to a suddendecrease in generation by immediately switching a subset of loads to thegrid to ensure continuous power supply to all loads, and thenselectively switching certain loads to the generator, ensuring the totalpower consumed by loads connected to the generator does not exceed thegenerator capacity. Illustrative embodiments of methods for carrying outthese steps are disclosed in FIGS. 9B and 9C.

At step 803, the controller executing method 800 may control a switchingcircuit (e.g. switching circuit 103 of FIG. 1) to connect the loads topower sources according to the subsets selected in step 802. At step804, the controller may wait a period of time before looping back tostep 801. In some embodiments, the controller may remain at step 804until an interrupt is received, which may trigger a loop back to step804. In one example, an interrupt may be received when there is a changein load or generation measurements. In some embodiments, the controllermay utilize the time spend at step 804 to concurrently carry outadditional calculations. For example, the controller may, at step 802,switch loads according to the methods of FIGS. 9B-9E to obtain a loaddivision which may be preferable to the previous load division yet notoptimal, and at step 804 the method may run a BF or DP method to obtainan optimal division.

Still referring to step 804 of FIG. 8, the controller may utilize thetime before looping back to step 801 to consider likely future scenariosit may need to respond to. For example, the controller may attempt topredict future load and/or generation measurements, and run BF methods,DP methods or other methods to solve the LSP considering likely futurescenarios. For example, the controller may run LSP-solving methodsconsidering generation which is 90% or 110% of the current generationlevel, and considering load consumption which is 90% or 110% of thecurrent load consumption level. Carrying out LSP-solving methods inadvance may allow more effective real-time responses, (i.e. when changesin generation and/or load consumption are measured). Load consumptionprediction and generation prediction are both highly studied fields ofresearch, with a myriad of forecasting methods available. For reasonablysimple and predictable electrical systems, linear regression models mayprovide adequate load and/or generation forecasts. For more complexsystems, Artificial Neural Networks or other machine learning techniquesmay provide more accurate forecasts of power generation and/orconsumption.

In some systems, a local memory device may log previously measured loadand generation values for future reference. Logged measurements mayprovide indications of future changes in load and/or generation. Forexample, in some home electrical systems, a kitchen oven is frequentlyturned off at 6 pm at dinnertime, or a television set is frequentlyturned on at 9 pm on Tuesday evenings for a favorite TV show. In somesystems, the hour of day at which shade from a tree begins to cover aphotovoltaic panel may vary by a few minutes on a day-to-day basis (asthe days get gradually longer or shorter), and a trained controller maybe able to predict at what exact minute a dip in PV generation mayoccur. At step 804, a controller may access logged historical data topredict likely load and generation measurements, and calculatepreferable load division accordingly.

Reference is now made to FIG. 9A, which illustrates a flow diagram for a“Brute force” (BF) method for calculating an optimal division of loadsinto subsets. The illustrated method assumes that a system has twopossible power sources—a generator (e.g. power generation system 101 ofFIG. 1) and a grid (e.g. grid 108 of FIG. 1). It is assumed that a listof N loads (e.g. loads 102) is accessible via an array P, with theelement P[i] indicating the power consumed by the i^(th) load. It isassumed that the current power output capacity of the generator is knownand referred to as the parameter Generation. At step 901, one or morelocal variables may be initialized. In one example, the parametercurrent_maximum (representing the current maximum load consumption beconnected to the generator so far) may be initialized to zero.Additionally, the parameter current_optimum (representing a stringindicating the optimal division of the loads into subsets) may beinitialized to a null or empty string. Additionally, the parameter i(representing a counter for loop 910) may be initialized to 0. At step911, execution of loop 910 may begin. Loop 910 may be executed 2^(N)times, once for each possible division of the loads into two groups. Insystems where three power supplies are available (e.g. a grid, generatorand storage device), the loop may be executed 3^(N) times, once for eachpossible division of the loads into three groups.

At step 911, it is determined whether counter i is less than 2^(N−1). Ifthe counter i is less than 2^(N−1), processing may proceed to step 912,where additional parameters may be initialized. The parameter b is setto be the binary representation of i, with i as the loop counter of loop910. For example, at the 18-th iteration of loop 910, the parameter bwill contain the string ‘10001’, which is the binary representation ofthe decimal number 17. The parameter total_load, representing thecurrent total load consumption assumed to be connected to the generatoraccording to the arrangement indicated by b, is set to zero.Additionally, the parameter j, the counter for loop 920, is set to zero.The loop 920 will be executed once for each character of string b. Atstep 921, processing of loop 920 begins by determining if the currentvalue of parameter j (the counter for loop 920) is less than the valueof length(b)−1. If the current value of parameter j is less than thevalue of length(b)−1, processing continues to step 922, where thecharacter of parameter b is evaluated. If the j^(th) character is ‘1’,the j^(th) load is considered connected to the generator. Therefore, atstep 923, the consumption level of the j^(th) load is added to theparameter total_load, which represents the current total loadconsumption connected to the generator according to the arrangementindicated by parameter b. After step 923 and/or if the evaluation atstep 922 indicates that the jth load is not ‘1’, processing continues tostep 924, where the loop counter j is incremented by 1. Processing mayreturn to step 921, where processing of loop 920 may then repeat for theincremented value j if j is less than the value of length(b)−1.Alternatively, processing of loop 920 may end (i.e. if j is not lessthan the value of length(b)−1). After loop 920 is executed j times, thevariable total_load will contain the total load consumption connected tothe generator according to the arrangement indicated by parameter b. Ifprocessing of loop 920 is complete (i.e. if j is not less than the valueof length(b)−1), processing may proceed to step 913.

At step 913, the parameter total_load, which represents the total loadconsumption connected to the generator, is compared to the parameterGeneration, which represents the current power output capacity of thegenerator (i.e. the maximum allowed consumption to be connected to thegenerator), and to the parameter current_maximum, which represents themaximum load consumption connected to the generator so far. In someembodiments, the parameter Generation may indicate an allowableconsumption which may be less than the current power generated by agenerator (e.g. if excess generation margins are desired, as discussedwith regard to FIG. 2). If the parameter total_load is less than orequal to the parameter Generation and the parameter total_load isgreater than the parameter current_maximum, the variable current_maximumis set to equal total_load, and the variable current_optimum,representing a string indicating the optimal division of the loads intosubsets, is set to equal the string b. In other words, the parameterscurrent_maximum and current_optimum track the best solution so far, i.e.the solution which divides the loads such that the generator-connectedload is maximized without surpassing Generation. Current_optimumrepresents the division of loads into groups (the i^(th) character ofcurrent_optimum being set to ‘1’ if the i^(th) load is connected to thegenerator, and ‘0’ otherwise), and current_maximum tracks the numericalvalue of the total load connected to generator under the arrangementrepresented by current_optimum. After the updating of the parameters instep 914 (or if, at step 913, it is determined that total_load is notgreater than Generation and/or that total_load is not greater thancurrent_maximum), processing may proceed to step 915, where the value ofthe parameter i, representing the loop counter for loop 910, may beincremented by 1. Processing may then return to step 911, where it maybe determined whether counter i is less than 2^(N−1). If the counter iis less than 2^(N−1), execution of loop 910 may be repeated. If thedetermination at step 911 indicates that counter i is not less than2^(N−1), execution of loop 910 may end. Once execution of loop 910 iscomplete, all 2^(N) load subsets have been considered, with theparameters current_maximum and current_optimum containing the maximumload consumption that has been connected to the generator and a stringindicating the optimal division of the loads into subsets, respectively.These parameters may be output at step 902.

Reference is now made to FIG. 9B, which illustrates a method fordetermining which loads to switch between power sources. Method 980 maybe an example of a method for selecting a load to switch from agenerator (e.g. power generation system 101) to a grid (e.g. grid 108).Method 980 may be triggered in response to a condition where thecumulative consumption of a group of loads connected to a generatorexceeds the capacity of the generator. Method 980 may receive as input alist of loads currently connected to the generator (referred to hereinas parameter gen_loads), a list of loads currently connected to the grid(referred to herein as parameter grid_loads), and the maximum allowedconsumption to be connected to the generator (referred to herein asparameter generation). At step 921, a set of parameters may beinitialized. For example, the total consumption of the loads connectedto the generator may be calculated (shown as “sum(gen_loads)”) andstored in the parameter sum_loads. Additionally, the difference betweensum_loads and generation may be calculated and stored in the parametermargin. The difference stored in the parameter margin may indicate theminimal load consumption which may be required to be switched from thegenerator to the grid. Additionally, a parameter to_move, representingthe load to be switched, may be initialized to a float infinity value(shown as float(“inf”)). Processing may proceed to step 931, the firststep within loop 930. Loop 930 may be executed once for each loadconnected to the generator. Each generator-connected load is referred toin turn (i.e. at one loop iteration) as load_x. At step 931, the valueof load_x is compared both to the parameter margin, representing theload level which needs to be shed from the generator, and to theparameter to_move, representing the current load selected for switchingfrom the generator to the grid. If load_x is smaller than to_move andload_x is larger than or equal to margin, load_x is selected as the bestcandidate (so far) for switching from the generator to the grid, asswitching load_x from the generator reduces the totalgenerator-connected load consumption to the maximum acceptable level (orlower) while maximizing the generator-connected load consumption.Accordingly, at step 932, parameter to_move, representing the currentload selected for switching from the generator to the grid is set toequal load_x, the current load being evaluated. At step 934, it may bedetermined if there are additional loads in gen_loads (i.e. the list ofloads currently connected to the generator) which have not yet beenevaluated at step 931. If, at step 934, it is determined that there areone or more additional loads in gen_loads, processing may return to step931, where the analysis of loop 930 may be repeated for the next load ingen_loads. If, at step 934, it is determined that there are noadditional loads in gen_loads, execution of loop 930 is complete, andprocessing may proceed to step 922.

At step 922, the validity of to_move (the load selected by the executionof loop 930 to be switched from the generator to the grid) is evaluated.For example, if all generator-connected loads evaluated at step 931 aresmaller than margin, no load will be selected at step 932 (i.e. by loop930). If at step 922 no load_x has been selected as to_move (i.e. theparameter to_move is still equal its initial value of infinity), thenproceeding may proceed to step 923. At step 923, the largestgenerator-connected-load may be selected for switching from thegenerator to the grid. This step might not reduce the totalgenerator-connected-load consumption to an acceptable level, but it mayreduce the generator-connected-load consumption nonetheless. Method 980may be invoked additional times until the total generator-connected-loadconsumption reaches an acceptable level. After step 923 and/or if aload_x has been selected as to_move at step 922 (i.e. the value ofto_move is different than the initial value of infinity), processing mayproceed to step 924. At step 924, the selected load for switching fromthe generator to the grid (load_x) is removed from the gen_loads list.At step 925, the selected load for switching from the generator to thegrid (load_x) is appended to the grid_loads list. At step 926, theupdated lists gen_loads and grid_loads are returned.

Reference is now made to FIG. 9C, which illustrates a method forselecting a load to switch from a grid (e.g. grid 108 of FIG. 1) to agenerator (e.g. power generation system 101). Method 940 may betriggered in response to a condition where the cumulative consumption ofa group of loads connected to a generator is less than the capacity ofthe generator. Method 940 may receive as input a list of loads currentlyconnected to the generator (herein referred to as gen_loads), a list ofloads currently connected to the grid (herein referred to asgrid_loads), and the maximum allowed consumption to be connected to thegenerator (herein referred to as generation). At step 941, a set ofparameters may be initialized. For example, the total consumption of theloads connected to the generator is calculated (shown as sum(gen_loads))and stored in the variable sum_loads. Additionally, the differencebetween generation, representing the maximum allowed consumption to beconnected to the generator, and sum_loads, representing the totalconsumption of the loads connected to the generator is calculated andstored in the parameter margin, the difference indicating the additionalload consumption which may be added to the generator without exceedingthe generator's capacity. Additionally, a variable to_move isinitialized for storing the load to be switched from the grid to thegenerator. Processing may then proceed to step 951, which is the firststep of loop 950. Loop 950 may be executed once for each load connectedto the grid. Each grid-connected load is referred to in turn (i.e. atone loop iteration) as load_x. At step 951, the value of load_x iscompared both to the parameter margin (i.e. the load level which may beswitched from the grid to the generator) and to the current loadselected for switching from the grid to the generator, represented byparameter to_move. If load_x is larger than to_move and load_x issmaller than or equal to margin, load_x is selected as the bestcandidate (so far) for switching from the grid to the generator, asswitching x from the grid to the generator (currently) maximizes thetotal generator-connected load consumption while remaining below orbeing equal to the maximum acceptable load consumption. Accordingly, ifload_x is larger than to_move and load_x is smaller than or equal tomargin, at step 952, the parameter to_move is set to be equal to load_x.At step 953, it may be determined if there are additional loads ingrid_loads (i.e. the list of loads currently connected to the generator)which have not yet been evaluated by step 951. If, at step 953, it isdetermined that there are one or more additional loads in grid_loads,processing may return to step 951, where the analysis of loop 950 may berepeated for the next load in grid_loads. If, at step 953, it isdetermined that there are no additional loads in grid_loads, executionof loop 950 is complete, and processing may proceed to step 942.

At step 942, the validity of to_move (the load selected by the executionof loop 950 to be switched from the grid to the generator) is evaluated.For example, if all grid-connected loads evaluated at step 951 arelarger than margin, no load will be selected at step 952. If, at step952, a load load_x has been selected for to_move (i.e. the value ofto_move is determined, at step 942, to be greater than zero), processingmay proceed to step 943, where load_x may be appended to gen_loads (i.e.the list of loads connected to the generator), and to step 944, whereload_x may be removed from grid_loads (i.e. the list of loads connectedto the grid) If no load has been selected for to_move (i.e. i.e. thevalue of to_move is determined, at step 942, to not be greater thanzero), processing may proceed to step 945, where it may be determined ifa storage device (e.g. storage device 104) is available for storing theexcess power generated. If a storage device is available, processing mayproceed to step 946, where a function to command the storage device tobegin storing margin power may be called. If no storage device isavailable at step 945, processing may proceed to step 947, whereadditional loads may be connected to the generator or the powergenerated by the generator may be decreased, as described with regard tostep 207 of FIG. 2. After each of steps 944, 946, and 947, processingmay proceed to step 948, where the updated lists gen_loads andgrid_loads may be output.

Reference is now made to FIG. 9D, which illustrates an example of amethod for switching one or more loads from a generator (e.g. powergeneration system 101) to a grid (e.g. grid 108). Method 970 may betriggered in response to a condition where the cumulative consumption ofa group of loads connected to a generator exceeds the capacity of thegenerator. Method 970 may receive as input one or more parametersindicating the total consumption connected to a generator(total_gen_loads), the total consumption connected to a grid(total_grid_loads), lists of indices indicating which loads areconnected to the generator and grid, (index_gen_loads andindex_grid_loads, respectively)and the current maximum allowableconsumption for connecting to the generator (generation). The differencebetween total_gen_loads and generation may be calculated and stored inthe parameter margin. The difference stored in the parameter margin mayindicate the minimal load consumption which may be required to beswitched from the generator to the grid. Method 970 might not assumethat individual load consumption values are known, and may attempt toreduce the total load connected to the generator without knowingindividual load consumption values. Loop 960 of method 970 may executeas long as total_gen_loads is greater than generation, i.e. it may benecessary to reduce the load consumption connected to the generator. If,at step 961, total_gen_loads is greater than generation, agenerator-connected load from index_gen_loads at randomly selected indexi may be selected at step 962. At step 963, the selected load may beswitched from the generator to the grid. At step 964, an updated set ofparameters, including total_gen_loads, total_grid_loads,index_gen_loads, index_grid_loads may be calculated. Loop 960 may thenbe repeated until the total generator-connected load consumption is lessthan generation, i.e. the allowable maximum total generator-connectedconsumption.

If, at step 961, total_gen_loads is not greater than generation, theresultant division of loads amongst the grid and generator (resultingfrom the one or more executions of loop 960) may be evaluated. If theone or more executions of loop 960 switched a large load from thegenerator to the grid, a large excess generation margin may have beencreated and it may be desirable to switch a potentially smaller loadfrom the grid to the generator in order to maximize thegenerator-connected load consumption while not exceeding generation.Accordingly, at step 971, if the difference between the parametergeneration and the parameter margin is greater than the parametertotal_gen_loads, at step 972, a method to switch or more loads from agrid (e.g. grid 108) to a generator (e.g. power generation system 101)may be called. An example method to switch or more loads from a grid toa generator is discussed below in reference to FIG. 9E. Calling themethod to switch or more loads from a grid to a generator may includethe transmittal of one or more calculated parameters (i.e. theparameters calculated at step 964 in the last execution of loop 960),such as total_gen_loads, total_grid_loads, index_gen_loads,index_grid_loads.

Referring to FIG. 9E, an example of a method for switching one or moreloads from a grid (e.g. grid 108) to a generator (e.g. power generationsystem 101). Method 990 may be triggered in response to a conditionwhere the cumulative consumption of a group of loads connected to agenerator is below the capacity of the generator. Method 990 may receiveas input a variable indicating the total consumption connected to agenerator (total_gen_loads), the total consumption connected to a grid(total_grid_loads), lists of indices indicating which loads areconnected to the generator and grid, respectively (index_gen_loads andindex_grid_loads), and the current maximum allowable consumption forconnecting to the generator (generation). Additionally, the differencebetween generation, representing the maximum allowed consumption to beconnected to the generator, and total_gen_loads, representing the totalconsumption of the loads connected to the generator is calculated andstored in the parameter margin, the difference indicating the additionalload consumption which may be switched from the grid to the generatorwithout exceeding the generator's capacity. Method 990 might not assumethat individual load consumption values are known, and may attempt toincrease the total load connected to the generator without knowingindividual load consumption values. The execution of loop 999 may berepeated as long as total_gen_loads is smaller than generation, i.e. itmay be desirable to increase the load consumption connected to thegenerator. If, at step 981, total_gen_loads is smaller than generation,a grid-connected load from index_grid_loads at random index i may beselected. At step 983, the selected load (shown as load[i]) may beswitched from the grid to the generator. At step 984, the resultantparameters total_gen_loads, total_grid_loads, index_gen_loads,index_grid_loads may be calculated. Execution of loop 999 may thenrepeat until the total generator-connected load consumption is greaterthan generation, i.e. the allowable maximum total grid-connectedconsumption.

If, at step 981, total_gen_loads is not smaller than generation,execution of loop 999 is complete, and at step 991, the resultantdivision of loads amongst the grid and generator may be evaluated. If,at step 983, a large load was switched from the grid to the generator, alarge negative generation margin may have been created, and it may bedesirable to switch a load from the generator to the grid in order toreduce the generator-connected load consumption to below generation.Accordingly, if at step 991, if the parameter total_gen_loads is greaterthan the difference between the values of parameters generation andmargin, method 970, as discussed above in reference to FIG. 9D, may becalled. As noted above, method 970 is an example of a method forswitching one or more loads from a generator (e.g. power generationsystem 101) to a grid (e.g. grid 108). Calling the method to switch ormore loads from the generator to the grid may include the transmittal ofone or more calculated parameters (i.e. the calculation of theseparameters at step 984 in the last iteration of loop 999), such astotal_gen_loads, total_grid_loads, index_gen_loads, index_grid_loads

It is to be understood that direct application of methods 970 and 990described above may result in oscillatory behavior, where loads areconstantly switched between the generator and the grid. Such constantswitching might not, in some embodiments, be desirable. In someembodiments, methods 970 and 990 may be slightly modified to include“stopping conditions,” effectively maintaining an acceptable division ofloads between the grid and generator for a period of time, beforere-evaluating the load division (e.g. after a period of time has elapsedor an interrupt has been received).

Reference is now made to FIG. 10, which is a part-schematic, part blockdiagram of a system for voltage synchronization according toillustrative embodiments. In some electrical systems, it may bedesirable to synchronize the voltage output by a grid and the voltageoutput by an alternative power source. For example, if a load isswitched from an electrical grid to the output of a PV inverter, if thePV inverter and the grid are not in-phase, the load may experience avoltage magnitude jump even if both the inverter and the grid output analternating-current (AC) voltage at identical magnitudes andfrequencies. Some loads may be sensitive to a sudden jump in the voltagemagnitude of a power supply and load components may be damaged in eventof a voltage jump. Grid 1028 may be similar to or the same as grid 108of FIG. 1. The voltage of grid 1028 may be continuously sampled byvoltmeter 1024, with voltmeter 1024 providing the samples to controller1025. Controller 1025 may control the operation of PV inverter 1023. PVinverter 1023 may receive input power from photovoltaic (PV) source1021. PV source 1021 may be similar to or the same as PV source 311 ofFIG. 3. PV source 1021 and PV inverter 1023 may together comprise agenerator similar to or the same as power generation system 101 of FIG.1 or power generation system 301 of FIG. 3.

Upon receiving voltage samples from voltmeter 1024, controller 1025 maycontrol the switching elements of inverter 1023 to track the voltageoutput by grid 1028. PV inverters may output a voltage according to areference voltage signal, and by using the voltage of grid 1028 as areference voltage signal for PV inverter 1023, synchronized voltagesignals may be output by grid 1028 and PV inverter 1023. If synchronizedvoltage signals are provided, loads switched from grid 1028 to PVinverter 1023 or from PV inverter 1023 to grid 1028 might not beaffected by the switching. Furthermore, synchronizing the output voltageof PV inverter 1023 and the output voltage of grid 1028 may facilitatecoupling PV inverter 1023 to grid 1028, enabling PV inverter 1023 toinject power to grid 1028 (e.g. in return for “feed-in” payment).

In the illustrative embodiments disclosed herein, photovoltaic modulesare used to exemplify energy sources which may make use of the novelfeatures disclosed. In some embodiments, the energy sources may includesolar shingles, batteries, wind or hydroelectric turbines, fuel cells,hydroelectric generators or other energy sources in addition to orinstead of photovoltaic panels. The methods and features disclosedherein may be applied to alternative energy sources such as those listedabove, and the mentioning of photovoltaic modules as energy sources isnot intended to be limiting in this respect.

It is noted that various connections are set forth between elementsherein. These connections are described in general and, unless specifiedotherwise, may be direct or indirect; this specification is not intendedto be limiting in this respect. Further, elements of one embodiment maybe combined with elements from other embodiments in appropriatecombinations or subcombinations. For example, power generation system101 of FIG. 1 may replace power generation system 300 of FIG. 3.

1. An electrical system comprising: a photovoltaic generator; a utilityelectrical grid; a plurality of switches configured to receive powerfrom the photovoltaic generator and the utility electrical grid; aplurality of electrical loads, wherein each electrical load isconnectable to the photovoltaic generator or the utility electricalgrid; and a controller configured to connect or disconnect one or moreof the plurality of electrical loads to and from the photovoltaicgenerator and the utility electrical grid, wherein the controller isconfigured to: determine that power generated by the photovoltaicgenerator exceeds a power consumption of one or more first electricalloads connected to the photovoltaic generator by a first value,determine that a power consumption of each electrical load of one ormore second electrical loads connected to the utility electrical gridexceeds the first value, and store excess power generated by thephotovoltaic generator to a storage device.
 2. The electrical system ofclaim 1, wherein each switch comprises a plurality of throws, andwherein the plurality of throws maintain the photovoltaic generator andthe utility electrical grid in a disconnected state.
 3. The electricalsystem of claim 1, wherein the storage device is configured to outputpower to one or more of the plurality of electrical loads.
 4. Theelectrical system of claim 1, wherein the controller is configuredreduce the power generated by the photovoltaic generator when thestorage device is fully charged.
 5. The electrical system of claim 3,wherein each switch comprises a plurality of throws, and furthercomprising an inverter connected between the photovoltaic generator anda first throw of the plurality of throws.
 6. The electrical system ofclaim 5, further comprising a circuit breaker connected between thephotovoltaic generator and the utility electrical grid.
 7. Theelectrical system of claim 1, wherein the controller is configured toswitch one or more third electrical loads connected to the utilityelectrical grid when a total power consumption of the one or more thirdelectrical loads connected to the utility electrical grid does notexceed the first value.
 8. The electrical system of claim 7, whereineach switch comprises a plurality of throws, and wherein the controlleris configured to switch each electrical load of the one or more thirdelectrical loads by controlling a first throw of the plurality of throwsto disconnect an electrical load from the photovoltaic generator beforeconnecting the electrical load to the utility electrical grid.
 9. Theelectrical system of claim 8, wherein each throw comprises a transistorcoupled in parallel to an electromechanical relay, and wherein toconnect a disconnected electrical load, each of the plurality of throwsfirst connects the transistor, then while the transistor is connectedconnects the electromechanical relay, and then when theelectromechanical relay is connected disconnects the transistor.
 10. Theelectrical system of claim 8, wherein each throw comprises a transistorcoupled in parallel to an electromechanical relay, and wherein todisconnect a connected electrical load, each of the plurality of throwsfirst connects the transistor, then while the transistor is connecteddisconnects the electromechanical relay, and then when theelectromechanical relay is disconnected disconnects the transistor. 11.The electrical system of claim 1, wherein one or more switches of theplurality of switches comprises a circuit breaker.
 12. The electricalsystem of claim 1, wherein the plurality of switches are housed by asingle enclosure.
 13. The electrical system of claim 1, furthercomprising a communication device configured for transmitting powermeasurements to the controller.
 14. A method for operating an electricalsystem, the electrical system comprising a photovoltaic generator, autility electrical grid, a plurality of switches, each of the pluralityof switches configured to receive power from the photovoltaic generatorand the utility electrical grid, and a plurality of electrical loads,each of the plurality of electrical loads connected to the photovoltaicgenerator or the utility electrical grid, the method comprising:monitoring electrical power output by the photovoltaic generator;monitoring electrical power consumed by one or more first electricalloads, of the plurality of electrical loads, connected to thephotovoltaic generator, and responsive to determining that theelectrical power output by the photovoltaic generator exceeds a powerconsumption of the one or more first electrical loads by a first valueand a determination that a power consumption of each electrical load ofone or more second electrical loads of the plurality of electricalloads, connected to the utility electrical grid of the electrical systemexceeds the first value, storing excess power generated by thephotovoltaic generator to a storage device.
 15. The method of claim 14,further comprising switching one or more third electrical loadsconnected to the utility electrical grid when a total power consumptionof the one or more third electrical loads connected to the utilityelectrical grid does not exceed the first value.
 16. The method of claim15, wherein each switch comprises a plurality of throws, and wherein theswitching of each electrical load of the one or more third electricalloads comprises controlling a first throw of the plurality of throws todisconnect an electrical load from the photovoltaic generator beforeconnecting the electrical load to the utility electrical grid.
 17. Themethod of claim 16, wherein each throw comprises a transistor coupled inparallel to an electromechanical relay, and wherein to connect adisconnected electrical load, each of the plurality of throws firstconnects the transistor, then while the transistor is connected connectsthe electromechanical relay, and then when the electromechanical relayis connected disconnects the transistor.
 18. The method of claim 16,wherein each throw comprises a transistor coupled in parallel to anelectromechanical relay, and wherein to disconnect a connectedelectrical load, each of the plurality of throws first connects thetransistor, then while the transistor is connected disconnects theelectromechanical relay, and then when the electromechanical relay isdisconnected disconnects the transistor.
 19. The method of claim 14,further comprising reducing the power generated by the photovoltaicgenerator when the storage device is fully charged.
 20. The method ofclaim 15, further comprising sending a notification to an operatoridentifying the one or more first electrical loads, the one or moresecond electrical loads, or the one or more third electrical loads.